<?xml version='1.0' encoding='UTF-8' ?>
<!--
    Document   : productType
    Created on : 16 Jul 11, 23:06:18
    Author     : Administrator
-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<ui:composition template="/templates/page.xhtml"
                xmlns:f="http://java.sun.com/jsf/core"
                xmlns:h="http://java.sun.com/jsf/html"
                xmlns:ice="http://www.icesoft.com/icefaces/component"
                xmlns:ui="http://java.sun.com/jsf/facelets">
    <ui:define name="title">Product Type</ui:define>

    <ui:define name="content">
        <h:form id="form">
            <ice:panelGroup styleClass="exampleBox selectionContainer" >
                <ice:outputText value="MASTER PRODUCT TYPE" style="font-weight: bolder; font-size: 20px"/><br/><br/><br/>
                <ice:panelGrid columns="2" styleClass="verticalAlignTop" >
                    <ice:inputText id="txtId" binding="#{productTypeBean.txtId}" rendered="false"/>
                    <ice:outputText value="Name"/>
                    <ice:inputText id="txtName" binding="#{productTypeBean.txtName}" disabled="true" required="true" requiredMessage="Please enter 'Name' field"/>
                    <ice:outputText value="Information"/>
                    <ice:inputText binding="#{productTypeBean.txtDescription}" disabled="true"/>

                    <h:messages errorStyle="color: red" infoStyle="color: green" layout="table"/>
                </ice:panelGrid>
                <ice:panelGroup>
                    <ice:commandButton binding="#{productTypeBean.btnAdd}" value="Add" action="#{productTypeBean.add_action()}"/>
                    <ice:commandButton binding="#{productTypeBean.btnEdit}" value="Edit" action="#{productTypeBean.edit_action()}" rendered="false"/> 
                    <ice:commandButton binding="#{productTypeBean.btnRemove}" value="Remove" action="#{productTypeBean.remove_action()}" rendered="false"/> 
                    <ice:commandButton binding="#{productTypeBean.btnSave}" value="Save" action="#{productTypeBean.save_action()}" rendered="false"/> 
                    <ice:commandButton binding="#{productTypeBean.btnCancel}" value="Cancel" action="#{productTypeBean.cancel_action()}" rendered="false"/> 
                </ice:panelGroup>
            </ice:panelGroup>

            <!-- DataTable with RowSelector Component -->
            <ice:panelGroup styleClass="exampleBox " >
                <ice:dataTable id="dt"
                               var="item"
                               value="#{productTypeBean.dataTables}"
                               rows="10" 
                               columnClasses="tableCol" >
                    <ice:column>
                        <ice:rowSelector id="selected"
                                         selectionListener="#{productTypeBean.rowSelectionListener}"
                                         />
                        <f:facet name="header"><ice:outputText value="ID"/></f:facet>
                        <ice:outputText id="Number" value="#{item.productTypeId}"/>
                    </ice:column>

                    <ice:column>
                        <f:facet name="header"><ice:outputText value="Name"/></f:facet>
                        <ice:outputText value="#{item.productTypeName}"/>
                    </ice:column>

                    <ice:column>
                        <f:facet name="header"><ice:outputText value="Information"/></f:facet>
                        <ice:outputText value="#{item.productTypeInformation}"/>
                    </ice:column>

                    <ice:column>
                        <f:facet name="header"><ice:outputText value="Active"/></f:facet>
                        <ice:outputText value="#{item.productTypeIsactive}"/>
                    </ice:column>
                </ice:dataTable>
            </ice:panelGroup>

            <ice:panelGroup style="float:left;width:420px;">
                <center>
                    <ice:dataPaginator id="dataScroll_1"
                                       for="dt"
                                       fastStep="5"
                                       paginator="true"
                                       paginatorMaxPages="10">
                        <f:facet name="first">
                            <ice:graphicImage id="firstpage_1"
                                              url="/assets/styles/icefusion/css-images/arrow-first.gif"
                                              style="border:none;"
                                              title="First Page"/>
                        </f:facet>
                        <f:facet name="last">
                            <ice:graphicImage id="lastpage_1"
                                              url="/assets/styles/icefusion/css-images/arrow-last.gif"
                                              style="border:none;"
                                              title="Last Page"/>
                        </f:facet>
                        <f:facet name="previous">
                            <ice:graphicImage id="previouspage_1"
                                              url="/assets/styles/icefusion/css-images/arrow-previous.gif"
                                              style="border:none;"
                                              title="Previous Page"/>
                        </f:facet>
                        <f:facet name="next">
                            <ice:graphicImage id="nextpage_1"
                                              url="/assets/styles/icefusion/css-images/arrow-next.gif"
                                              style="border:none;"
                                              title="Next Page"/>
                        </f:facet>
                        <f:facet name="fastforward">
                            <ice:graphicImage id="fastforward_1"
                                              url="/assets/styles/icefusion/css-images/arrow-ff.gif"
                                              style="border:none;"
                                              title="Fast Forward"/>
                        </f:facet>
                        <f:facet name="fastrewind">
                            <ice:graphicImage id="fastrewind_1"
                                              url="/assets/styles/icefusion/css-images/arrow-fr.gif"
                                              style="border:none;"
                                              title="Fast Backward"/>
                        </f:facet>
                    </ice:dataPaginator>
                </center>
            </ice:panelGroup>
        </h:form>
    </ui:define>
</ui:composition>